package com.google.code.sharecontent.model;

import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;

public class Status  extends Model {
	
	public static final String ADDED = "ADDED";
	public static final String AUTH = "AUTH";
	public static final String WORKING = "WORKING";
	public static final String DELETED = "DELETED";
	public static final String ACTIVE = "ACTIVE";//Раздается
	public static final String TEMP_NOT_ACCESS = "TEMP_NOT_ACCESS";
	public static final String BLOKED = "BLOKED";
	public static final String IGNORED = "IGNORED";
	
	public static final String FOUNDED = "FOUNDED";
	public static final String TO_PROCESS = "TO_PROCESS";
	public static final String NOT_ACCESS_FOR_PROCESS = "NOT_ACCESS_FOR_PROCESS";
	public static final String WAITING_CONFIRM = "WAITING_CONFIRM";

	public static final String SCANNED = "SCANNED";
	
	public static List<String> statusesListFoContents = new ArrayList<String>() {
		private static final long serialVersionUID = 8440280111158250605L;
		{
			add(Status.FOUNDED);
			add(Status.TO_PROCESS);
			add(Status.NOT_ACCESS_FOR_PROCESS);
			add(Status.WAITING_CONFIRM);
			add(Status.ACTIVE);
			add(Status.IGNORED);
		}
	};
	
	public static Map<String, List<String>> nextContentStatuses = new HashMap<String, List<String>>() {
		private static final long serialVersionUID = -2790090851768318752L;
		{
			put(Status.FOUNDED, new ArrayList<String>());
			get(Status.FOUNDED).add(Status.DELETED);
			get(Status.FOUNDED).add(Status.TO_PROCESS);
			get(Status.FOUNDED).add(Status.IGNORED);
			
			put(Status.IGNORED, new ArrayList<String>());
			get(Status.IGNORED).add(Status.DELETED);
			get(Status.IGNORED).add(Status.TO_PROCESS);
			
			put(Status.TO_PROCESS, new ArrayList<String>());
			get(Status.TO_PROCESS).add(Status.DELETED);
			get(Status.TO_PROCESS).add(Status.WORKING);

			
			put(Status.WORKING, new ArrayList<String>());
			get(Status.WORKING).add(Status.WAITING_CONFIRM);
			get(Status.WORKING).add(Status.NOT_ACCESS_FOR_PROCESS);

			put(Status.NOT_ACCESS_FOR_PROCESS, new ArrayList<String>());
			get(Status.NOT_ACCESS_FOR_PROCESS).add(Status.DELETED);
			get(Status.NOT_ACCESS_FOR_PROCESS).add(Status.TO_PROCESS);

			put(Status.WAITING_CONFIRM, new ArrayList<String>());
			get(Status.WAITING_CONFIRM).add(Status.DELETED);
			get(Status.WAITING_CONFIRM).add(Status.ACTIVE);

			put(Status.ACTIVE, new ArrayList<String>());
			get(Status.ACTIVE).add(Status.DELETED);
			get(Status.ACTIVE).add(Status.TEMP_NOT_ACCESS);
			get(Status.ACTIVE).add(Status.BLOKED);

			put(Status.TEMP_NOT_ACCESS, new ArrayList<String>());
			get(Status.TEMP_NOT_ACCESS).add(Status.DELETED);
			get(Status.TEMP_NOT_ACCESS).add(Status.ACTIVE);

			put(Status.BLOKED, new ArrayList<String>());
			get(Status.BLOKED).add(Status.DELETED);
			get(Status.BLOKED).add(Status.ACTIVE);
			
			put(Status.DELETED, new ArrayList<String>());
		}
	};
	
	private String code;
	private String name;
	
	public String getCode() {
		return code;
	}
	public void setCode(String code) {
		this.code = code;
	}
	public String getName() {
		return name;
	}
	public void setName(String name) {
		this.name = name;
	}
}
